Conversation
- Add helper functions to parser.test.ts (expectParse, expectProvidersSet, expectModelSet) - Add helper functions to file_edit_replace.test.ts (setupFile, readFile, executeReplace) - Consolidate repetitive parse-and-assert patterns - Use table-driven test for missing args cases - Reduce parser.test.ts from 213 to 196 lines (8% reduction) - Reduce file_edit_replace.test.ts from 563 to 551 lines (partial refactoring) - All tests pass, no behavior changes
duynguyen020304
pushed a commit
to duynguyen020304/mux
that referenced
this pull request
May 10, 2026
…RY, tests Batch 1 — Compile Errors & Correctness: - Add TOGGLE_KANBAN to KEYBIND_LABELS and KEYBIND_GROUPS (coder#1) - Fix Ctrl+K conflict → Ctrl+Shift+K to avoid PREV_WORKSPACE collision (coder#2) - Add TOGGLE_KANBAN dispatch handler in App.tsx (coder#3) - Fix dirty-cache in promoteQueuedTask: move flag clearing after moveTask (coder#5) - Wrap 4 IPC helpers in KanbanBoard with try/catch (coder#4) Batch 2 — Consistency & DRY: - Deduplicate KanbanColumnSchema: import from canonical orpc/schemas (coder#6) - Remove unused KanbanBoardData import from kanbanStorage.test (coder#7) - Remove dead KANBAN_STORAGE_KEYS constant (coder#8) - Replace console.warn with log helper in kanbanStorage (coder#9) - Replace useEffect form reset with key prop in TaskDetailModal (coder#10) - Remove unsafe {} as KanbanTask cast, use EMPTY_FORM pattern (coder#11) - Add loading state + error logging to KanbanView (coder#12, coder#13) - Add KANBAN_STATUS_LABELS helper, use in TaskDetailModal (coder#14) - Validate column membership in reorderTasks (coder#15) - Use KanbanTaskPriority type import in TaskCreateModal (coder#16) Batch 3 — Tests: - Add 4 tests for updateColumn (coder#17) - Add 3 tests for promoteQueuedTask (coder#18) - Rename misleading test 'rejects empty title' → 'accepts empty title' (coder#19) 43 tests pass (was 36). No typecheck or lint regressions.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Refactors test files to reduce duplication by extracting helper functions.
Changes
parser.test.ts: 213 → 196 lines (-8%)
expectParse(),expectProvidersSet(),expectModelSet()helpersfile_edit_replace.test.ts: 563 → 551 lines (partial)
setupFile(),readFile(),executeReplace()helpersAll tests pass ✅